package acount;

import book.Booklist;
import operation.IOperation;

import java.util.Scanner;

import operation.*;

public class Normal extends User{

    public Normal() {
        this.iOperations = new IOperation[4];
        iOperations[0] = new Exit();
        iOperations[1] = new Borrow();
        iOperations[2] = new Search();
        iOperations[3] = new Return();
    }

    @Override
    public void operate(int c, Booklist booklist) {
        iOperations[c].work(booklist);
    }

    public void menu() {
        System.out.println("1.借阅图书");
        System.out.println("2.查找图书");
        System.out.println("3.归还图书");
        System.out.println("0.退出");
        System.out.print("请输入操作对应的数字：");
    }
}
